﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace BLL.Helper.Exception
{
    public class BusinessException : System.Exception
    {
        // Methods
        public BusinessException()
        {
        }

        public BusinessException(string message)
            : base(message)
        {
        }

        protected BusinessException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }

        public BusinessException(string message, System.Exception inner)
            : base(message, inner)
        {
        }

        public BusinessException(string message, string fieldWithError)
            : base(message)
        {
            this.FieldWithError = fieldWithError;
        }

        // Properties
        public string FieldWithError { get; set; }
    }
}
